<template>
    <div class="imageDetailCon">
        <mt-swipe :auto="0">
            <mt-swipe-item v-for="(item, i) in imageList" :key="i">
                <img :src="item" alt="">
            </mt-swipe-item>
        </mt-swipe>
    </div>
</template>
<script>
export default {
    data(){
        return {
            imageList: null,
            id:this.$route.params.id
        }
    },
    created(){
        this.getImage()
        console.log(this.imageList)
    },
    methods: {
        getImage(){
            this.$http.get("/girl.json").then(
                data => {
                    this.imageList = data.body[this.id].pics;
                },() => {
                    Toast("获取数据出错")
                }
            )
        }
    }
}
</script>
<style lang="scss" scoped>
.imageDetailCon{
    height: 100%;
    background-color: #333;
    .mint-swipe{
        .mint-swipe-item{
            display: table-cell;
            vertical-align: middle;
            
            img{
                width: 100%;
                line-height: 100%;
            }
        }
        
       
    }
}
</style>
